<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>1</title>
	<script src="http://libs.baidu.com/jquery/2.0.0/jquery.min.js"></script>
</head>
<body>
	<div id="testDiv">jq data() 无法跨框架传递</div>
	<iframe id="testIframe" src="2.html"></iframe>
	<button onclick="javascript:$('#testIframe').attr('myid', 'hello');$('#testDiv').data('myid', 'hello')">设置</button>
	<button onclick="javascript:alert($('#testIframe').attr('myid'));alert($('#testDiv').data('myid'))">获取</button>
</body>
</html>